package edu.hawaii.solardecathlon.page.electricity;

import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
import org.apache.wicket.model.IModel;

/**
 * Overrides ModalWindow in order to store the Electricity object to easy parsing in the modal
 * window.
 * 
 * @author Bret Ikehara
 */
public class ElectricityModalWindow extends ModalWindow {

  /**
   * Serial ID.
   */
  private static final long serialVersionUID = -5197635570678522684L;
  private Electricity elec;

  /**
   * Creates the constructor.
   * 
   * @param id String
   */
  public ElectricityModalWindow(String id) {
    super(id);
    this.elec = null;
  }

  /**
   * Creates the constructor.
   * 
   * @param id String
   * @param model IModel<?>
   */
  public ElectricityModalWindow(String id, IModel<?> model) {
    super(id, model);
    this.elec = null;
  }

  /**
   * Gets the electricity object.
   * 
   * @return Electricity
   */
  public Electricity getElec() {
    return elec;
  }

  /**
   * Sets the Electricity object.
   * 
   * @param elec Electricity
   */
  public void setElec(Electricity elec) {
    this.elec = elec;
  }

}
